﻿
namespace BEGDC.PreContract.DAL
{
    using System;
    using System.Collections.Generic;
    using Castle.ActiveRecord;
    using NHibernate.Expression;


    [ActiveRecord]
    public partial class CATAssignment : ActiveRecordBase<CATAssignment>
    {
		#region Const Definition
		
		public const string CONST_CATAssignmentID						= "CATAssignmentID";
		public const string CONST_CATID									= "CATID";
		public const string CONST_EmployeeID							= "EmployeeID";

		#endregion
		
        #region Member Variables
        // Primary Key
        private System.Int32 _cATAssignmentID;
        
        // Non Key

        // Parents
        private Employee _employeeID;
        private CAT _cATID;
        
        
		

        #endregion

        public CATAssignment() {
               
        }
        
        #region Properties
        // Primary Key        
		
		#if (SQLServer)
        [PrimaryKey]
		#else
		[PrimaryKey(PrimaryKeyType.Native, SequenceName = "SEQ_CATASSIGNMENT_CATASSIGNMENTID")]
		#endif
        public System.Int32 CATAssignmentID {
            get { return this._cATAssignmentID; }
            set {  this._cATAssignmentID = value; }
        }
        
        // Non Key
        
        // Parent Relationships
        [BelongsTo("EmployeeID")]
        public Employee EmployeeID {
            get { return this._employeeID; }
            set { this._employeeID = value; }
        }
        
        [BelongsTo("CATID")]
        public CAT CATID {
            get { return this._cATID; }
            set { this._cATID = value; }
        }
        
        // Child Relationships
        
		
        #endregion
		
		// Clone
		public CATAssignment Clone()
		{
			CATAssignment newCATAssignment = new CATAssignment();
			
            newCATAssignment.EmployeeID = this._employeeID ; 
            newCATAssignment.CATID = this._cATID ; 
			return newCATAssignment;
		}
    }
}



